package com.education.service.statistics.feign.fallback;

import com.education.result.R;
import com.education.service.statistics.feign.UcenterMemberService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

/**
 * 远程调用 - 用户注册统计
 * Created by Lance on 2020/07/12 17:04
 */
@Slf4j
@Service
public class UcenterMemberServiceFallBack implements UcenterMemberService {

    /**
     * 根据日期 - 统计注册人数
     * @param day
     * @return
     */
    @Override
    public R countRegisterNum(String day) {
        //错误日志
        log.warn("熔断器被执行");
        return R.ok().data("registerNum", 0);
    }
}
